Embedded Programming

Starting and basic website server

  1. Went to OH and got an led to shine with arduino index
  2. Wanted to try micropython due to python experience
  3. Got micropython to work on the board super easily but then I learned you can't go back to arduino unless you reset the board because you physically put micropython into the board
  4. Switched to micropython and got it to work
  5. first time connecting to web server

Pivot

  1. I want to build an lcd display that shows messages for people in my house to read or potentially everyone can join the local network and also add messages
  2. I learned that digital displays are extremely expensive and I do not want to spend that much money
  3. screen list
  4. The solution then became to get a tiny one for free at lab, but then realized I have no idea how to hook it up. I read through the data sheet and know what the 4 pins go to but not sure how to get from pins to pins on micro controllers
  5. How to connect photo
  6. Time to pivot again and instead I worked on connecting an api every time the server is launched
  7. I tried one api and it through weird errors and I have not done this before , so chatgpt was a major help and great teacher through building all of the code through this. Would highly reccomend. It even helped build out better debugging except statements which helped. The reason chatgpt works well with this is everytime you run the code and get an error you can give it back to chatgpt and it will iterate with you
  8. Using Gpt

API connection Quote of the day

  1. I switched to a new api where I did not need an api key in order to quickly test this out and it ended up working. Would reccomend testing api's and working with them because you get way more accesible information at your finger tips.
  2. For some reason the webserver port was occupied so I switched from default 80 to 8080 and it worked. However, it onyl showed me source code instead of reading the html. I had to switch back to 80 and it worked again not sure why.
  3. I added Css a little bit to help organize the page for now and have a quote of the day. Next steps would include having server up regularly and having the server ping the api from time to time or when a button is chosen.
  4. port error css web

Group Project. Micropython versus Arduino quick notes. Group notes : here

Performance
  1. The performance of micropython is not as fast as arduino and writing straight C++ but for what I a doing it does not matter how fast it goes which I am thankful for. The Rp2040 has good enough performance for what I am doing with micropython.
  2. Additionally the arduino ide feels very clunky whenever I try to do anything on it.
  3. With straight C you can theoretically unlock the full potential of the hardware with low level code, but that is beyond what I am doing right now.
Work flow
  1. Python feels more approachable then C at this point because it is more readable and I have more experience with it.
  2. I also want to try C at some point thought because there is a tremendous amount of resources and community support behind it
  3. I am kinda curious though if I wanted to work on TinyMl if people write than in C because I think a lot of ML is written in python.